<include file="public/header"/>
    <!--促销列表-s-->
        <div id="goods_list">
            <foreach name="promote" item="list">
                <a href="{:U('Activity/discount_list',array('id'=>$list[id]))}">
                <div class="banner">
                    <img src="{$list[prom_img]|default='__STATIC__/images/pr_06.jpg'}"/>
                </div>
                <div class="cbaudience">
                    <div class="maleri30">
                        <p>{$list[title]}</p>
                        <p>{:date('Y.m.d',$list[start_time])}——{:date('Y.m.d',$list[end_time])}</p>
                    </div>
                </div>
                </a>
            </foreach>
        </div>
    <!--促销列表-e-->

    <!--加载更多S-->
    <notempty name="promote">
        <div id="getmore" style="font-size:.32rem;text-align: center;color:#888;padding:.25rem .24rem .4rem; clear:both">
            <a href="javascript:void(0)" onClick="ajax_sourch_submit()">点击加载更多</a>
        </div>
    </notempty>

    <!--加载更多E-->
</body>
<script>
    /**
     * 加载更多商品
     **/
    var  page = 1;
    function ajax_sourch_submit()
    {
        ++page;
        $.ajax({
            type : "GET",
            url:"/index.php?m=Mobile&c=Activity&a=promote_goods&is_ajax=1&p="+page,
            success: function(data) {
                if ($.trim(data) == '') {
                    $('#getmore').hide();
                } else {
                    $("#goods_list").append(data);
                }
            }
        });
    }
</script>
</html>
